<!--<header layout="row" id="header-main">
    <md-button id="stack-create" class="md-raised md-primary" flex="100"
               data-ng-click="stackListCtrl.openCreateSelect($event)">
        <i class="fa fa-stack"></i>
        {/'Create Stack' | translate/}
    </md-button>
</header>-->

<div layout="row" layout-wrap ng-flow-grid min-item-width="330" id="stack-list">
    <div class="flowGridItem">
        <div class="app-panel create-stack" id="stack-create" data-ng-click="stackListCtrl.openCreateSelect($event)">
                <i class="fa fa-plus-square" aria-hidden="true"></i>
                <div>{/'Create Stack' | translate/}</div>
        </div>
    </div>
    <div data-ng-repeat="stack in stackListCtrl.stacks | orderBy: 'stack.Services[0].CreatedAt' track by $index"
         class="flowGridItem"
         id="stack{/$index/}">
        <div class="app-panel">
            <header>
                <h1>
                    <a id="stack{/$index/}-name" data-ui-sref="stack.detail({stack_name: stack.Namespace})">{/stack.Namespace/}</a>
                </h1>
            </header>
            <table>
                <tr data-ng-repeat="service in stack.Services track by $index" id="{/stack.Namespace/}-services">
                    <td>
                        <a id="{/stack.Namespace/}-{/service.Name/}" data-ui-sref="stack.serviceDetail({stack_name: stack.Namespace, service_id: service.ID})">{/service.Name/}</a>
                    </td>
                    <td>{/service.NumTasksRunning/}/{/service.NumTasksTotal/}</td>
                    <td>
                        <md-menu ng-show="service.addrs.length" >
                            <a ng-click="$mdOpenMenu()"><i class="fa fa-link"></i></a>
                            <md-menu-content>
                                <md-menu-item ng-repeat="addr in service.addrs">    <md-button ng-href="http://{/addr.ip | ip/}:{/addr.port/}" ng-show="addr.ip" target='_blank'>{/addr.ip | ip/}:{/addr.port/}</md-button><span ng-hide="addr.ip">{/addr.port/}</span>
                                </md-menu-item>
                            </md-menu-content>
                        </md-menu>
                        <div ng-show="!service.addrs.length">{/'Not configured' | translate/}</div>
                    </td>
                </tr>
            </table>
            <div class="time">{/stack.Services[0].CreatedAt | date: 'yyyy-MM-dd HH:mm:ss' /}</div>
        </div>
    </div>
</div>
    